package com.intramirror.wd.service.security.service;


import com.google.common.collect.Lists;
import com.intramirror.wd.business.manage.UserManage;
import com.intramirror.wd.service.security.model.UserInfo;
import com.intramirror.wd.service.security.model.UserRole;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author mars
 */
@Service
public class UserRoleService {
    @Autowired
    private UserManage userManage;
    public List<UserRole> getRoleByUser(UserInfo user) {
        //需要重写权限
//        TransitWarehouseUser transitWarehouseUser = userManage.findUserRoleByUserId(user.getUserId());
//        if(transitWarehouseUser != null){ //用来区分那个质检仓登录的
//            return Lists.newArrayList(new UserRole("ROLE_ADMIN"));
//        }
        return null;
    }
}
